package com.itheima.demo1;

public class Tongji {
    public static void main(String[] args){
        int a;
        int x = 0;
        int sum = 0;
        for(a = 0;a <= 100;a = a + 2){
            System.out.println(a);
            sum = sum + a;
            x++;
        }
        System.out.println("偶数个数为"+(x-1));
        System.out.println("偶数和为"+sum);
    }
}
